<template>
    <el-table :data="list" style="width: 100%">
        <el-table-column prop="pregnancyId" label="序号"/>
        <el-table-column prop="auricle" label="种母耳号" />
        <el-table-column prop="pregnancyDay" label="妊检天数" />
        <el-table-column prop="buildingName" label="栋舍"/>
        <el-table-column prop="columnsName" label="栏位" />
        <el-table-column prop="pregnancyName" label="提示类型">
            <template v-slot="scope">
                <span v-if="scope.row.pregnancyName==1">妊娠前期</span>
                <span v-else>妊娠后期</span>
            </template>
        </el-table-column>
    </el-table>
</template>
<script setup lang="ts">
import {reactive,ref,onMounted} from 'vue'
import axios from 'axios';
const list=ref([])
const getlist=()=>{
    axios.post("http://localhost:5012/api/Prompt/pregnancyList",{}).then(res=>{
        console.log(res)
        list.value=res.data.data
    })
    
}
onMounted(()=>{
    getlist()
})
</script>